<?php

	function conectaMysql($userdb,$userpass,$dbname){
		$server = "localhost";
		$link	= mysql_connect($server,$userdb,$userpass) or die("ERROR DE CONEXION: ".mysql_error());
		mysql_select_db($dbname,$link) or die ("ERROR CON LA BASE DE DATOS: ".mysql_error());
		return $link;
	}
	
	function conectaSQL($userdb,$userpass,$dbname){
		$server = "localhost";
		$link2	= mssql_connect($server,$userdb,$userpass) or die("ERROR DE CONEXION: ".mssql_get_last_message());
		mssql_select_db($dbname,$link2) or die ("ERROR CON LA BASE DE DATOS: ".mssql_get_last_message());
		return $link2;
	}

?>
